<div class="col-sm-9 col-sm-offset-3 col-md-10 col-md-offset-2 main">
    <div class="breadcrumb_wrap">
        <ul class="breadcrumb">
            <li>您的位置：</li>
            <li> <a href="product_list.html">产品管理</a> <span class="divider">></span> </li>
            <li> <a href="product_list.html">产品信息</a> <span class="divider">></span> </li>
            <li class="active">修改商品信息</li>
        </ul>
    </div>
    <div class="product_con">
        <div class="title">
            <h3>产品基本信息</h3>
        </div>
        <div class="select_box " >
            <form class="form-horizontal" role="form">
                <div class="form-group col-md-4">
                    <label class="control-label">产品名：</label>
                    <input type="text" class="form-control" ng-model="goods.title">
                </div>
                <div class="form-group col-md-4">
                    <label class="control-label">产品编号：</label>
                    <input type="text" class="form-control" ng-model="goods.identifier">
                </div>
                <div class="form-group col-md-4">
                    <label class="control-label">产品类型：</label>
                    <select class="form-control" ng-model="goods.typeOne"  ng-change="getChildType('1')">
                        <option value="" disabled selected >--请选择--</option>
                        <option ng-repeat="tOne in typeOneList" value="{{tOne.id}}">{{tOne.title}}</option>
                    </select>
                </div>
                <div class="form-group col-md-4">
                    <label class="control-label">产品材质：</label>
                    <select class="form-control" ng-model="goods.type" ng-change="getChildType('2')" ng-disabled="haveScond=='1'">
                        <option value="" disabled selected>--请选择--</option>
                        <option ng-repeat="type in typeList" value="{{type.id}}">{{type.typeName}}</option>
                    </select>
                </div>
                <div class="form-group col-md-4">
                    <label class="control-label">产品样式：</label>
                    <select class="form-control" ng-model="goods.gstyle" ng-change="getPxByStyle()">
                        <option value="" disabled selected >--请选择--</option>
                        <option ng-repeat="style in gstyleList" value="{{style.id}}">{{style.typeName}}</option>
                    </select>
                </div>
                <div class="form-group col-md-4">
                    <label class="control-label">产品品型：</label>
                    <select class="form-control" ng-model="goods.px">
                        <option value="" disabled selected >--请选择--</option>
                        <option ng-repeat="px in pxList" value="{{px.id}}">{{px.title}}</option>
                    </select>
                </div>
                <div class="form-group col-md-4">
                    <label class="control-label">当日价格（元/g)：</label>
                    <input type="text" class="form-control" ng-model="goods.price">
                </div>
                <div class="form-group col-md-4">
                    <label class="control-label">库存：</label>
                    <input type="text" class="form-control" ng-model="goods.number">
                </div>
                <div class="form-group col-md-12">
                    <label class="control-label">产品规格：</label>
                    <div ng-repeat="item in goodsWeightList" class="weight">
                        <div class="col-sm-2">
                            <input type="text" class="form-control" ng-model="item.minWeight" ></div>
                        <div  class="col-sm-1">--</div>
                        <div class="col-sm-2" >
                            <input type="text" class="form-control" ng-model="item.maxWeight"></div>
                        <div class="col-sm-2">
                            <label class="control-label" >附加工费：</label>
                        </div>
                        <div class="col-sm-2">
                            <input type="text" class="form-control" ng-model="item.jgf">
                        </div>
                        <div class="col-sm-2" style="text-align: center">
                        <input type="button" style="width: 50px" class="form-control" value="删除" ng-click="deleteGoodsWeight($index)">
                    </div>
                    </div>
                    <input type="button" value="添加" ng-click="addGoodsWeight()">
                </div>
                <div class="form-group col-sm-12">
                    <label class="control-label">产品描述：</label>
                    <textarea class="form-control" rows="3" ng-model="goods.des"></textarea>
                </div>
            </form>
        </div>
    </div>
    <div class="product_con">
        <div class="title">
            <h3>产品图片</h3>
        </div>
        <div class="select_box pic_box" >
            <form class="form-horizontal" role="form">
                <div class="form-group col-sm-12">
                    <label class="control-label">展示图：</label>
                    <ul class="upload-ul clearfix">
                        <input type="file" class="webuploader-container clearfix">
                        <li class="diyUploadHover">
                            <div class="viewThumb" >
                            <img ng-if="goods.iconUrl==undefined||goods.iconUrl==''" class="" ng-src="/app/images/goodsDefault.gif">
                            <img ng-if="goods.iconUrl!=undefined&&goods.iconUrl!=''" ng-src="/dapi/download/getImageIO?imgUrl={{goods.iconUrl}}" />
                            </div>
                            <button ng-if="goods.iconUrl!=undefined&&goods.iconUrl!=''" type="button" class="close" ng-click="deleteIconUrl(goods.id)"><i class="glyphicon glyphicon-remove-circle"></i></button>
                        </li>
                    </ul>
                    <div class="button_box">
                        <button type="button" class="btn btn-primary btn_add" ng-click="uploadPic()">上传图片</button>
                        <!--<button type="button" class="btn btn-primary back btn_del diyCancelAll" >全部取消</button>-->
                    </div>
                </div>

            <div class="form-group col-sm-12">
                <label class="control-label">轮播图：</label>
                <ul class="upload-ul clearfix">
                    <li class="diyUploadHover" ng-repeat="item in imgUrlList">
                        <div class="viewThumb" >
                            <img ng-src="/dapi/download/getImageIO?imgUrl={{item.picUrl}}"/>
                        </div>
                        <button type="button" class="close" ng-click="deletePic(item)"><i class="glyphicon glyphicon-remove-circle"></i></button>
                    </li>
                </ul>
                <div class="container-fuild kv-main">
                    <form enctype="multipart/form-data">
                        <div>
                            <input id="file-1" type="file" multiple class="file" data-overwrite-initial="false" data-min-file-count="2" >
                        </div>
                    </form>
                </div>
            </div>
            </form>
        </div>
    </div>
    <div class="product_con" ng-if="evaluateList.length>0">
        <div class="title">
            <h3>产品评价</h3>
        </div>
        <div class="select_box " >
            <div class="table-responsive con_list comment_list">
                <table class="table table-striped">
                    <thead>
                    <tr>
                        <th>用户名</th>
                        <th>评论时间</th>
                        <th>评论内容</th>
                        <th>操作</th>
                    </tr>
                    </thead>
                    <tbody>
                    <tr ng-repeat="evaluate in evaluateList">
                        <td >{{evaluate.publishUserName}}</td>
                        <td>{{evaluate.publishTime}}</td>
                        <td style="width:50%;">{{evaluate.content}}</td>
                        <td class="ops"><button type="button" class="btn btn-primary del" ng-click="deleteEvaluate(evaluate.id)">删除</button></td>
                    </tr>
                    </tbody>
                </table>
            </div>
            <!--<div class="comment_add">-->
                <!--<div class="s_title">新增</div>-->
                <!--<form class="form-horizontal" role="form">-->
                    <!--<div class="form-group col-md-4">-->
                        <!--<label class="control-label">用户名：</label>-->
                        <!--<input type="text" class="form-control">-->
                    <!--</div>-->
                    <!--<div class="form-group col-md-4">-->
                        <!--<label class="control-label">评价时间：</label>-->
                        <!--<input type="text" class="form-control" placeholder="&#45;&#45;请选择&#45;&#45;">-->
                        <!--<i class="glyphicon glyphicon-calendar"></i> </div>-->
                    <!--<div class="form-group col-sm-12">-->
                        <!--<label class="control-label">评价内容：</label>-->
                        <!--<textarea class="form-control" rows="3"></textarea>-->
                    <!--</div>-->
                    <!--<div class="form-group col-sm-12 button_box table_btn_box editor_btn_box ">-->
                        <!--<button type="button" class="btn btn-primary btn_add" >确认</button>-->
                        <!--<button type="button" class="btn btn-primary back" >取消</button>-->
                    <!--</div>-->
                <!--</form>-->
            <!--</div>-->
        </div>
    </div>
    <div class="button_box table_btn_box editor_btn_box ">
        <button type="button" class="btn btn-primary btn_add" ng-click="submitGoods()" ><i class="glyphicon glyphicon-ok"></i>提交</button>
        <!--<a href="/xdd/common/goods_list"><button type="button" class="btn btn-primary back"><i class="glyphicon glyphicon-chevron-left"></i>返回</button></a>-->
    </div>
</div>